package br.com.datatraffic.fiscal.entidades;
// Generated 10/07/2009 10:49:54 by Hibernate Tools 3.2.0.b9


    
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * HistoricoTicket generated by hbm2java
 */
@Entity
@Table(name="TBHISTORICO_TICKET"
)
public class HistoricoTicket5  implements java.io.Serializable {


     private Long id;
     private Ticket5 ticket;
     private SituacaoPesagem situacaoPesagem;
     private SituacaoTicket5 situacaoTicket;
     private Date data;

    public HistoricoTicket5() {
    }

    public HistoricoTicket5(Long id, Ticket5 ticket, SituacaoPesagem situacaoPesagem, SituacaoTicket5 situacaoTicket, Date data) {
       this.id = id;
       this.ticket = ticket;
       this.situacaoPesagem = situacaoPesagem;
       this.situacaoTicket = situacaoTicket;
       this.data = data;
    }
   
     @Id 
     @SequenceGenerator(name = "SQ_TBHISTORICO_TICKET", sequenceName = "SQ_TBHISTORICO_TICKET", allocationSize=1)
     @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "SQ_TBHISTORICO_TICKET")
    @Column(name="HISTORICO_TICKET_ID", unique=true, nullable=false, precision=38, scale=0)
    public Long getId() {
        return this.id;
    }
    
    public void setId(Long id) {
        this.id = id;
    }
@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="TICKET_ID", nullable=false)
    public Ticket5 getTicket() {
        return this.ticket;
    }
    
    public void setTicket(Ticket5 ticket) {
        this.ticket = ticket;
    }
@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="SITUACAO_PESAGEM_ID", nullable=false)
    public SituacaoPesagem getSituacaoPesagem() {
        return this.situacaoPesagem;
    }
    
    public void setSituacaoPesagem(SituacaoPesagem situacaoPesagem) {
        this.situacaoPesagem = situacaoPesagem;
    }
@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="SITUACAO_TICKET_ID", nullable=false)
    public SituacaoTicket5 getSituacaoTicket() {
        return this.situacaoTicket;
    }
    
    public void setSituacaoTicket(SituacaoTicket5 situacaoTicket) {
        this.situacaoTicket = situacaoTicket;
    }
    
    @Temporal(TemporalType.TIMESTAMP)
    @Column(name="DATA", nullable=false)
    public Date getData() {
        return this.data;
    }
    
    public void setData(Date data) {
        this.data = data;
    }



  // The following is extra code specified in the hbm.xml files
    private static final long serialVersionUID = 1L;
  // end of extra code specified in the hbm.xml files

}


